from ultralytics import YOLO

model =YOLO("D:\\Codes\\ultralytics-main\\yolov8n.pt")

if __name__ == '__main__':

    model.train(model="D:\\Codes\\ultralytics-main\\yolov8n.pt",data="D:\\Codes\\ultralytics-main"
                                                                         "\\ultralytics\\cfg\\datasets\\mydata.yaml",
            epochs=100,imgsz=640,batch=16)

